<template>
<OrderViewHeader title="我的订单"/>
  <van-tabs v-model:active="active">
     <van-tab title="全部" name="allOrder">
       <OrderAIIView/>
     </van-tab>
    <van-tab title="待支付" name="payOrder">
      <OrderPayView type="1"/>
    </van-tab>
    <van-tab title="待收货" name="takeOrder">
      <OrderTakeView type="2"/>
    </van-tab>
    <van-tab title="待评价" name="AppraiseOrder">
      <OrderAppraiseView type="3"/>
    </van-tab>
  </van-tabs>
</template>
<script setup lang="ts">
import {useRoute} from "vue-router";
import OrderViewHeader from "@/components/PubHeaderComponent.vue"
import OrderAIIView from "@/views/OrderView/OrderAIIView.vue";
import OrderTakeView from "@/views/OrderView/OrderTakeView.vue";
import {onMounted, ref} from "vue";
import OrderPayView from "@/views/OrderView/OrderPayView.vue";
import OrderAppraiseView from "@/views/OrderView/OrderAppraiseView.vue";
const route=useRoute()
const active=ref<string>("allOrder")
onMounted(()=>{
  active.value=route.params.index as string
})
</script>

<style scoped lang="less">

</style>